package com.cedifie.syc.data.beans

import com.cedifie.syc.data.ASSycBuilder
import com.cedifie.syc.data.util.ASAesUtil
import com.google.gson.Gson

/**
 * Cedifie
 * @Author wwdeng
 * @CreateTime: 2024/12/24 19:25
 * @Annotation：短信提交参数类
 */
class ASSmsRequestParams(
    var path: String,
    var token: String = ASSycBuilder.token,
    var product: String = ASSycBuilder.product,
    var androidId: String = ASSycBuilder.androidId,
    var advertId: String = ASSycBuilder.advertId,
    var client: String = "ANDROID",
    var type: String? = null,
    var smsRecordsGzip: String? = "",
    var smsFetchType: String? = "",
    var firstSentTime: String? = "",
    var firstReceivedTime: String? = "",
    var past1DaySentCount: String? = "",
    var past1DayReceivedCount: String? = "",
    var past3DaySentCount: String? = "",
    var past3DayReceivedCount: String? = "",
    var past7DaySentCount: String? = "",
    var past7DayReceivedCount: String? = "",
    var past15DaySentCount: String? = "",
    var past15DayReceivedCount: String? = "",
    var past21DaySentCount: String? = "",
    var past21DayReceivedCount: String? = "",
    var past30DaySentCount: String? = "",
    var past30DayReceivedCount: String? = "",
    var past60DaySentCount: String? = "",
    var past60DayReceivedCount: String? = "",
    var past90DaySentCount: String? = "",
    var past90DayReceivedCount: String? = "",
    var past3DayReceivedMobileCount: String? = "",
    var totalCount: String? = ""
) {
    fun toEncryptParams(): String {
        path = path.replace("/", "")
        if (path.isBlank()) return ""

        val content = Gson().toJson(this).trim()
        return ASAesUtil.encryptDefault(content)
    }
}